<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@include file="../common/taglib.jsp" %>

<!DOCTYPE html>
<html>
  <head>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<title>我的首页</title>
	<meta http-equiv="X-UA-Compatible" content="IE=11; IE=10; IE=9; IE=8; IE=7; IE=EDGE">
	
	<link rel="stylesheet" type="text/css" href="<c:url value="/css/header.css"/>">
	<link rel="stylesheet" type="text/css" href="<c:url value="/css/common.css"/>">
	<link rel="stylesheet" type="text/css" href="<c:url value="/css/public.css"/>">
	<link rel="stylesheet" type="text/css" href="<c:url value="/css/default.css"/>">
	<link rel="stylesheet" type="text/css" href="<c:url value="/css/footer.css"/>">
	<script type="text/javascript" src="<c:url value="/js/jquery.min.js"/>"></script>
  </head>
  <script type="text/javascript">
  	function onload(value,url){
  		if(value==null || value==0){
  			alert("请先完善企业信息");
  			window.location.href="<c:url value="/company/register"/>";
  		}
  	}
  </script>
<body id="home" onload="onload(${hr.company.id})">

<jsp:include page="../common/hrheader.jsp"></jsp:include>

<div class="wrap clearfix">
  <div class="main"> 
   <div class="feeds-panel">
    <div class="control-box">
    <form:form method="post" action="" modelAttribute="jobModel" class="horizontal">
    	<input type="hidden" name="id" value="${job.id }">
    	<input type="hidden" name="publishTime" value="${job.publishTime }">
    	<input type="hidden" name="companyId" value="${hr.company.id }">
      <div class="box-title">
        <div class="additional"><span class="help-required">*</span>为必填项</div>
        <h2>发布的职位：${job.position }</h2>
      </div>
          <div class="steps-item">
            <div class="title">
              <em>1</em>职位基本信息
            </div>
            <div class="control-group">
              <label class="control-label"><span class="help-required">*</span>职位名称：</label>
              <div class="controls">                
                <div class="valid-row">
                	<input class="text span7" type="text" name="position"  value="${job.position }">
                	<span style="color:red"><form:errors path="position"></form:errors></span>
                </div>               
              </div>
            </div>
            <div class="control-group">
              <label class="control-label"><span class="help-required">*</span>行业：</label>
              <div class="controls">
                <div class="valid-row">
                	<input class="text span7" type="text" name="industry" value="${job.industry }"> 
                	<span style="color:red"><form:errors path="industry"></form:errors></span>              
                </div>
              </div>
            </div>
            <div class="control-group work-area">
              <label class="control-label"><span class="help-required">*</span>工作地点：</label>
              <div class="controls">             
                <div class="valid-row">
                	<input class="text span7" type="text" name="workplace"  value="${job.workplace }"> 
                	<span style="color:red"><form:errors path="workplace"></form:errors></span>              
                </div>
             </div>
            </div>
            <div class="control-group">
              <label class="control-label"><span class="help-required">*</span>税前年薪：</label>             
              <div class="controls valid-row">
                <div class="span span7">
                  	<input class="text span5" type="number" name="salary" maxlength="3" min=0 value="${job.salary }">&nbsp;<span class="text-warning">万元</span>
                </div>               
              </div>        
     		</div>
     	</div>
          <hr>
          <div class="steps-item">
            <div class="title"><em>2</em>职位要求</div>
            <div class="sub-title"><em>基本要求</em></div>
            <div class="control-group">
              <label class="control-label">专业要求：</label>
              <div class="controls">             
                <div class="valid-row">
                	<input class="text span7" type="text" name="major" value="${job.major }" >
                	<span style="color:red"><form:errors path="major"></form:errors></span>
                </div>
             </div>
            </div>          
          
            <div class="control-group">
              <label class="control-label">工作年限：</label>           
              <div class="controls">
                <div class="valid-row">
                  <input class="text span7" type="text" name="experience" value="${job.experience }">&nbsp;年以上
                  <span style="color:red"><form:errors path="experience"></form:errors></span>
                </div>
              </div>
            </div>
            <div class="control-group">
              <label class="control-label">学历要求：</label>
              <div class="controls">
                <div class="valid-row">
                  <input class="text span7" type="text" name="education" value="${job.education }">&nbsp;以上
                  <span style="color:red"><form:errors path="education"></form:errors></span>
                </div>
              </div>
            </div>
                                 
            <div class="sub-title"><em><span class="help-required">*</span>职位描述</em></div>
            <div class="control-group">
              <div class="controls">
                <div class="valid-row">
                  <textarea class="span span10" rows="5" name="description" >${job.description }</textarea>
                  <span style="color:red"><form:errors path="description"></form:errors></span>
                </div>
              </div>
            </div>        
          </div>
          
          <hr>
          <div class="steps-item">
            <div class="title">
              <em>3</em>其他信息
            </div>
            <div class="control-group">
              <label class="control-label">应聘简历发送至：</label>
              <div class="controls email-list">             
	             <ul>
	               <li class="valid-row"><input type="email" class="text span7" name="mailbox" value="${job.mailbox }">
	             </ul> 
	             <span style="color:red"><form:errors path="mailbox"></form:errors></span>             
              </div>
            </div>
            <div class="control-group">
              <label class="control-label">截止时间：</label>
              <div class="controls">
                <div class="valid-row">
                  <input class="text span7" type="date" name="deadline" value="${job.deadline }">
                </div>
              </div>
            </div>
          </div>
          <div class="form-actions">     	           
            	<input  type="submit" class="btn btn-large btn-primary" value="再发布">
            	<a class="btn btn-large btn-light" href="<c:url value="/job/remove/${job.id }"/>" >删除职位</a>            
          </div>
           <br>
    </form:form>
  </div>
  </div>
</div>

</div>

<jsp:include page="../common/footer.jsp"></jsp:include>


</body>
</html>